<html>
<head><meta charset="utf-8"><title>release / acquire resources · t-lang/wg-unsafe-code-guidelines · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/136281-t-lang/wg-unsafe-code-guidelines/index.html">t-lang/wg-unsafe-code-guidelines</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release.20.2F.20acquire.20resources.html">release / acquire resources</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="203866635"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release%20/%20acquire%20resources/near/203866635" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release.20.2F.20acquire.20resources.html#203866635">(Jul 14 2020 at 18:05)</a>:</h4>
<p>One of my back-burner goals is to one day figure out how to use any ordering other than <code>SeqCst</code>. Do y'all have any favorite resources for learning about how to use the orderings correctly?</p>



<a name="203866983"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release%20/%20acquire%20resources/near/203866983" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Amanieu <a href="https://rust-lang.github.io/zulip_archive/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release.20.2F.20acquire.20resources.html#203866983">(Jul 14 2020 at 18:08)</a>:</h4>
<p><a href="https://preshing.com/20120913/acquire-and-release-semantics/">https://preshing.com/20120913/acquire-and-release-semantics/</a></p>



<a name="203922669"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release%20/%20acquire%20resources/near/203922669" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> RalfJ <a href="https://rust-lang.github.io/zulip_archive/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release.20.2F.20acquire.20resources.html#203922669">(Jul 15 2020 at 07:15)</a>:</h4>
<p>The paper that made it click for me is <a href="https://plv.mpi-sws.org/sra/paper.pdf">https://plv.mpi-sws.org/sra/paper.pdf</a> (slides: <a href="https://www.cs.tau.ac.il/~orilahav/papers/popl16.pdf">https://www.cs.tau.ac.il/~orilahav/papers/popl16.pdf</a>). But I am not sure how accessible that is to non-PL-researchers.^^</p>



<a name="203924893"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release%20/%20acquire%20resources/near/203924893" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jacob Lifshay <a href="https://rust-lang.github.io/zulip_archive/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release.20.2F.20acquire.20resources.html#203924893">(Jul 15 2020 at 07:45)</a>:</h4>
<p>Very interesting proposal for a different memory model</p>



<a name="203925391"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release%20/%20acquire%20resources/near/203925391" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> RalfJ <a href="https://rust-lang.github.io/zulip_archive/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release.20.2F.20acquire.20resources.html#203925391">(Jul 15 2020 at 07:52)</a>:</h4>
<p>yeah it's slightly different from RA but very similar (the same without write-write races). one can obtain exactly RA using the same technique with a slight variation, and most intuition carries over.</p>



<a name="203929590"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release%20/%20acquire%20resources/near/203929590" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> RalfJ <a href="https://rust-lang.github.io/zulip_archive/stream/136281-t-lang/wg-unsafe-code-guidelines/topic/release.20.2F.20acquire.20resources.html#203929590">(Jul 15 2020 at 08:46)</a>:</h4>
<p><a href="https://drops.dagstuhl.de/opus/volltexte/2017/7275/pdf/LIPIcs-ECOOP-2017-17.pdf#section.2">This section</a> describes proper C++ release/acquire in the same style (i.e., as a variant of "strong release acquire").</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>